package br.com.pentagrama.service.ui.screen;

import javax.swing.BoxLayout;
import javax.swing.JApplet;

import br.com.pentagrama.service.DataStore;

public class StartScreen extends JApplet {
	@Override
	public void init() {
		setLayout(new BoxLayout(this.getContentPane(), BoxLayout.Y_AXIS));
		setSize(800, 600);
		
		DataStore ipRangeDataStore = new DataStore() {
			
			public void store(String key, String value) {
				System.out.println("[IP RANGES] Data stored: (" + key + ", " + value + ")");				
			}
		};
		
		DataStore portRangeDataStore = new DataStore() {
			
			public void store(String key, String value) {
				System.out.println("[PORT RANGES] Data stored: (" + key + ", " + value + ")");				
			}
		};
		
		RegistrationScreen ui = new RegistrationScreen(ipRangeDataStore, portRangeDataStore);
		ui.showIn(this);
		super.init();
	}
	
	public static void main (String[] args) {
		System.out.println("ok");
	}
}
